intermittently. Normally in page fault handler, the entry hit in vtlb shouldn't
be injected back to vtlb again, not to say meaningless -1UL. After this fix,
vtlb hit ratio also improves since guest svhpt entry may live longer.
Signed-off-by Kevin Tian <kevin.tian@intel.com>
// PAGE_SIZE mapping in the vhpt for now, else purging is complicated
else vhpt_insert(vaddr,pte,PAGE_SHIFT<<2);
#endif
- if (IorD & 0x4) return; // don't place in 1-entry TLB
+ if ((mp_pte == -1UL) || (IorD & 0x4)) return; // don't place in 1-entry TLB
if (IorD & 0x1) {
vcpu_set_tr_entry(&PSCBX(vcpu,itlb),pte,ps<<2,vaddr);
PSCBX(vcpu,itlb_pte) = mp_pte;